package com.kpmg.datalake.reportanalysis.listener;

import org.springframework.context.ApplicationListener;
import org.springframework.context.event.ContextRefreshedEvent;

import com.kpmg.datalake.reportanalysis.service.DataService;

/**
 * 初始化加载
 * @author Tony
 */
public class ApplicationStartup implements ApplicationListener<ContextRefreshedEvent> {

    @Override
    public void onApplicationEvent(ContextRefreshedEvent context) {
        DataService dataService=context.getApplicationContext().getBean(DataService.class);
        dataService.flushRequestStatus(true);
    }
}

